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Y,EAAAA,EAAMA,CAAAA,CAAAA,KAGb","sources":["webpack://_N_E/?95ab","webpack://_N_E/./pages/[slug].tsx","webpack://_N_E/./templates/default-layout/index.tsx","webpack://_N_E/"],"sourcesContent":["\n (window.__NEXT_P = window.__NEXT_P || []).push([\n \"/[slug]\",\n function () {\n return require(\"private-next-pages/[slug].tsx\");\n }\n ]);\n if(module.hot) {\n module.hot.dispose(function () {\n window.__NEXT_P.push([\"/[slug]\"])\n });\n }\n ","import { GetStaticPaths, GetStaticProps } from 'next'\nimport { IStaticContent, IStaticContentCollection } from '@/interfaces'\nimport { useRouter } from 'next/router'\nimport { getStaticPagesSlugs } from '@/functions'\nimport DefaultLayout from '@templates/default-layout'\nimport { SEO } from '@molecules/index'\nimport {\n GET_STATIC_PAGES_SLUGS_QUERY,\n apolloClient,\n getStaticPageQuery\n} from '@/client'\nimport { StaticPageContent } from '@organisms/index'\n\ninterface IStaticPagesProps {\n page?: IStaticContent\n}\n\ntype TStaticPaths = Array<{ params: { slug: string } }>\n\nexport const getStaticPaths: GetStaticPaths<{ slug: string }> = async () => {\n const paths: TStaticPaths = []\n try {\n const {\n data: {\n staticContentCollection: { items }\n }\n } = await apolloClient.query<{\n staticContentCollection: IStaticContentCollection\n }>({ query: GET_STATIC_PAGES_SLUGS_QUERY })\n if (items !== undefined)\n items.forEach(({ slug }: any) => {\n if (slug !== undefined && slug !== '') paths.push({ params: { slug } })\n })\n } catch (ex) { }\n if (paths.length === 0) {\n getStaticPagesSlugs().forEach((slug) => {\n paths.push({ params: { slug } })\n })\n }\n return {\n fallback: false,\n paths\n }\n}\n\nexport const getStaticProps: GetStaticProps = async ({\n params\n}) => {\n const props: IStaticPagesProps = {}\n try {\n if (params?.slug === undefined || typeof params.slug !== 'string')\n throw new Error('No params received')\n const {\n data: { staticContentCollection: pageItems }\n } = await apolloClient.query<{\n staticContentCollection: IStaticContentCollection\n }>({ query: getStaticPageQuery(params.slug) })\n if (pageItems.items !== undefined) props.page = pageItems.items[0]\n } catch (ex) { }\n return { props }\n}\n\nconst StaticPages = ({ page }: IStaticPagesProps) => {\n const router = useRouter()\n const seoParams = router.isFallback\n ? {}\n : {\n title: page?.metaTitle,\n description: page?.metaDescription,\n keywords: page?.metaKeywords\n }\n\n return (\n <>\n \n \n \n \n \n )\n}\n\nexport default StaticPages\n","import { FloatingButton } from '@atoms/index'\nimport { Footer, NavBar } from '@organisms/index'\nimport { PropsWithChildren } from 'react'\n\ninterface DefaultLayoutProps extends PropsWithChildren {\n displayFloatingButton?: boolean\n}\nexport default function DefaultLayout({\n children,\n displayFloatingButton = true\n}: DefaultLayoutProps) {\n return (\n <>\n \n
{children}
\n \n